<!-- index.html -->
<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>任务记录</title>
    <link rel="stylesheet" href="style.css">
</head>
<body>
    <div class="container">
        <header>
            <h1>我的任务清单</h1>
            <div class="input-group">
                <input type="text" id="taskInput" placeholder="添加新任务...">
                <button id="addTaskBtn">添加</button>
            </div>
        </header>

        <main>
            <div class="filter-buttons">
                <button class="filter-btn active" data-filter="all">全部</button>
                <button class="filter-btn" data-filter="active">未完成</button>
                <button class="filter-btn" data-filter="completed">已完成</button>
            </div>

            <ul id="taskList">
                <!-- 任务将在这里动态添加 -->
            </ul>
        </main>

        <footer>
            <p>剩余任务: <span id="remainingCount">0</span></p>
            <button id="clearCompleted">清除已完成</button>
        </footer>
    </div>

    <script src="script.js"></script>
</body>
</html>